<?php
/* @var $this AnalysisController */
$this->breadcrumbs=array(
	'综合控制台'=>array($this->pre_module_url.'/index/index'),
	'活动促销'=>array($this->pre_module_url.'/promotion/admin'),
	'等级优惠'=>array($this->pre_module_url.'/memTypeDiscount/admin'),
);


$emptyText = '<div class="no_meetgive bd_db ff_s"><span class="ico ico_tip"></span>还未创建“套餐优惠券”，现在去';
$emptyText .= CHtml::link(Yii::t('cmp','Create Promotion'),array('create'),array('class'=>'mem_btn mem_btn20'));
$emptyText .= '</div>';

?>
<table class="list_table list_table2" cellpadding="0" cellspacing="0" width="100%">
	<thead>
		<tr>
			<th width="22%" class="pl15">优惠名称</th>
			<th width="15%">开始日期</th>
			<th width="15%">结束日期</th>
			<th width="10%">产品数据</th>
			<th width="14%">状态</th>
			<th width="16%">操作</th>                                                       
		</tr>
	</thead>
</table>

<?php   
$this->widget('zii.widgets.CListView', array(  
    'dataProvider'=>$model->search(),  
    'itemView'=>'_view',    
    'emptyText'=>$emptyText, 
	'selectAll'=>array('ids[]','id[]'),
	'itemsTagName'=>'table',
	'itemsOptions'=>array('class'=>'list_table list_table2 promotion_box','width'=>'100%','cellpadding'=>0,'cellspacing'=>0),
	'artLink'=>array(
			//批量删除
			array(Yii::t('adm','Delete All'),$this->pre_module_url.'/memTypeDiscount/delete','确认批量删除选中项目！'),
	),
    'batchItem'=>array(  
        //创建优惠券
        CHtml::link(Yii::t('cmp','Create Promotion').'<b class="mem_bgx left"></b><b class="mem_bgx right"></b>',array('create'),array('class'=>'mem_bgx link_btn')),  
    ),  
    ));  
?>  

<script type="text/javascript">
$('.operate .view').bind('mouseover',function(){
	$(this).parent().addClass('hover')
})
$('.operate .view').bind('mouseout',function(){
	$(this).parent().removeClass('hover')
})
</script>